
<script type="text/javascript" src="../../assets/javascripts/checkRegisterForm.js"></script>

<%= form_for :user, :url => {:action => 'signup'}, :html => { :onsubmit => 'return checkRegisterForm ();' } do |f| %>
	<div class="form_box" style="width: 470px;">
		<div class="field_name">Userame*
		<%= f.text_field :name, :class => 'text_box', :id=> "username" %></div>

		<div class="field_name">Password*
		<%= f.password_field :password, :class=>'text_box', :id=>"password" %></div>

		<div class="field_name">Retype password*
		<%= f.password_field :password_confirmation, :class=>'text_box', :id=>"repassword" %></div>

		<div class="field_name">Email*
		<%= f.text_field :email, :class=>'text_box', :id=>"email" %></div>

		<div class="field_name">Phone
		<%= f.text_field :phone, :class=>'text_box' %></div>

		<div class="field_name">Address
		<%= f.text_field :address, :class=>'text_box' %></div>

		<div style="font-size: 14px; color: red;"class="field_name">Fields with * are required
		<%= f.submit 'Create Subject', :class=>'submit_button' %></div>
		
		<div class="lower">
			<div class="error_form" id="errorForm"></div>
		</div>
	</div>
	<% end %>

<% if flash[:notice] == "fail" %>
	<script type="text/javascript">usernameDuplicate ();</script>
<%	end %>